<html>
<head>
  <meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="icon" href="../../favicon.ico">

    <title>Off Canvas Template for Bootstrap</title>

    <!-- Bootstrap core CSS -->
    <link href="assets/css/bootstrap.min.css" rel="stylesheet">

    <!-- Custom styles for this template -->
    <link href="assets/css/offcanvas.css" rel="stylesheet">
    <link href="assets/css/style.css" rel="stylesheet">
    <!-- Just for debugging purposes. Don't actually copy these 2 lines! -->
    <!--[if lt IE 9]>
    <script src="assets/js/ie8-responsive-file-warning.js"></script><![endif]-->
    <script src="assets/js/ie-emulation-modes-warning.js"></script>
</head>
<body>
<nav class="navbar navbar-fixed-top navbar-inverse">
  <div class="container-fluid">
    <!-- Brand and toggle get grouped for better mobile display -->
    <div class="navbar-header">
      <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
        <span class="sr-only">Toggle navigation</span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
      </button>
     
    </div>

    <!-- Collect the nav links, forms, and other content for toggling -->
    <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
        <ul class="nav navbar-nav">
            <li><a href="index.php?c=index&m=index">首页</a></li>
            <li><a href="index.php?c=index&m=listall&tid=1">川菜</a></li>
            <li><a href="index.php?c=index&m=listall&tid=2">徽菜</a></li>
            <li><a href="index.php?c=index&m=listall&tid=3">鲁菜</a></li>
            <li><a href="index.php?c=index&m=listall&tid=4">闽菜</a></li>
            <li><a href="index.php?c=index&m=listall&tid=5">苏菜</a></li>
            <li><a href="index.php?c=index&m=listall&tid=6">湘菜</a></li>
            <li><a href="index.php?c=index&m=listall&tid=7">粤菜</a></li>
            <li><a href="index.php?c=index&m=listall&tid=8">浙江菜</a></li>
        </ul>
        <form class="navbar-form navbar-right" role="search" method="post" action="index.php?c=index&m=search">
             <input type="text" class="form-control" name="foodname" placeholder="请输入搜索内容">
             <button type="submit" class="btn btn-default">搜索</button>
        </form>
        <ul class="nav navbar-nav navbar-right">
              <?php session_start(); 
              if(isset($_SESSION["uname"])){ ?>
              <li><a href="index.php?c=index&m=logout">注销</a></li>
              <li><a href="index.php?c=index&m=reguser">注册</a></li>
              <li class="active"><a href="#" >欢迎 
              
                 <?php echo " ".$_SESSION["uname"]." ";}
                else {?> 
              <li role="presentation"><a href="index.php?c=index&m=login">登陆</a></li>
              <li role="presentation"><a href="index.php?c=index&m=reguser">注册</a></li>
              <li class="active"><a href="#" >欢迎  
                <?php echo "您";}
                 ?>访问本站</a></li>
        </ul>
    </div><!-- /.navbar-collapse -->
  </div><!-- /.container-fluid -->
</nav>

<div class="container">

    <div class="row row-offcanvas row-offcanvas-right">

        <div class="col-xs-12 col-sm-9">


            <div class="row">
              <div class="col-xs-12 col-lg-12 mlist">
                  <h2>专栏所有美食</h2>
                    <?php 
                        foreach ($data['listall'] as $row) {  
                    ?>
                  <ul class="list-inline row text-center">
                  <li class="col-xs-6 col-lg-3">
                    <img src="upload/<?php echo $row["pic"]; ?>" class="responsive img-thumbnail"/>
                    <p><a href="index.php?c=index&m=content&vid=<?php echo $row['vid']; ?>"><?php echo $row["foodname"];?></a></p>
                  </li>
                    <?php  }?>
                  </ul>   
              </div>
            </div>
        </div>
    </div>
</div>
</body>
</html>